﻿using System;
using Dos.ORM;

namespace Dos.Model
{
    /// <summary>
    /// 实体类lpsos_key。(属性说明自动提取数据库字段的描述信息)
    /// </summary>
    [Table("lpsos_key")]
    [Serializable]
    public partial class lpsos_key : Entity
    {
        #region Model
        private int _ID;
        private string _Name;
        private string _Summary;
        private DateTime? _AddTime;

        /// <summary>
        /// 
        /// </summary>
        [Field("ID")]
        public int ID
        {
            get { return _ID; }
            set
            {
                this.OnPropertyValueChange("ID");
                this._ID = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        [Field("Name")]
        public string Name
        {
            get { return _Name; }
            set
            {
                this.OnPropertyValueChange("Name");
                this._Name = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        [Field("Summary")]
        public string Summary
        {
            get { return _Summary; }
            set
            {
                this.OnPropertyValueChange("Summary");
                this._Summary = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        [Field("AddTime")]
        public DateTime? AddTime
        {
            get { return _AddTime; }
            set
            {
                this.OnPropertyValueChange("AddTime");
                this._AddTime = value;
            }
        }
        #endregion

        #region Method
        /// <summary>
        /// 获取实体中的主键列
        /// </summary>
        public override Field[] GetPrimaryKeyFields()
        {
            return new Field[] {
                _.ID,
            };
        }
        /// <summary>
        /// 获取列信息
        /// </summary>
        public override Field[] GetFields()
        {
            return new Field[] {
                _.ID,
                _.Name,
                _.Summary,
                _.AddTime,
            };
        }
        /// <summary>
        /// 获取值信息
        /// </summary>
        public override object[] GetValues()
        {
            return new object[] {
                this._ID,
                this._Name,
                this._Summary,
                this._AddTime,
            };
        }
        /// <summary>
        /// 是否是v1.10.5.6及以上版本实体。
        /// </summary>
        /// <returns></returns>
        public override bool V1_10_5_6_Plus()
        {
            return true;
        }
        #endregion

        #region _Field
        /// <summary>
        /// 字段信息
        /// </summary>
        public class _
        {
            /// <summary>
            /// * 
            /// </summary>
            public readonly static Field All = new Field("*", "lpsos_key");
            /// <summary>
			/// 
			/// </summary>
			public readonly static Field ID = new Field("ID", "lpsos_key", "");
            /// <summary>
			/// 
			/// </summary>
			public readonly static Field Name = new Field("Name", "lpsos_key", "");
            /// <summary>
			/// 
			/// </summary>
			public readonly static Field Summary = new Field("Summary", "lpsos_key", "");
            /// <summary>
			/// 
			/// </summary>
			public readonly static Field AddTime = new Field("AddTime", "lpsos_key", "");
        }
        #endregion
    }
}